package com.zit.java.pojo;

import org.springframework.core.serializer.Deserializer;

import java.io.IOException;
import java.io.InputStream;
import java.io.Serializable;
import java.util.Date;

public class Employee implements Serializable, Deserializer {



        private int id;
        private Date time;
        private String address;

    public Employee() {
    }


    public Employee(int id, Date time, String address) {
        this.id = id;
        this.time = time;
        this.address = address;
    }

    @Override
    public String toString() {
        return "Employee{" +
                "id=" + id +
                ", time=" + time +
                ", address='" + address + '\'' +
                '}';
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public Date getTime() {
        return time;
    }

    public void setTime(Date time) {
        this.time = time;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    /**
     * Read (assemble) an object of type T from the given InputStream.
     * <p>Note: Implementations should not close the given InputStream
     * (or any decorators of that InputStream) but rather leave this up
     * to the caller.
     *
     * @param inputStream the input stream
     * @return the deserialized object
     * @throws IOException in case of errors reading from the stream
     */
    @Override
    public Object deserialize(InputStream inputStream) throws IOException {
        return null;
    }
}
